﻿//using AutoMapper;
//using BCGM.MedicalWisdom.Common.Seed;
//using BCGM.MedicalWisdom.IServices.Orders;
//using BCGM.MedicalWisdom.Model.Models;
////using BCGM.MedicalWisdom.Model.Models.Order;
//using BCGM.MedicalWisdom.Model.ViewModels.Order;
//using BCGM.MedicalWisdom.Repository.BASE;
//using BCGM.MedicalWisdom.Services.BASE;
//using Grpc.Core;
//using Microsoft.AspNetCore.Mvc.RazorPages;
//using MongoDB.Bson;
//using OfficeOpenXml.FormulaParsing.Excel.Functions.DateTime;
//using SQLitePCL;
//using System;
//using System.Collections.Generic;
//using System.Linq;
//using System.Linq.Expressions;
//using System.Text;
//using System.Threading.Tasks;

//namespace BCGM.MedicalWisdom.Services.Orders
//{
//    public class DoctorServices : BaseServices<Doctor>,IDoctorServices
//    {
//        private readonly IBaseRepository<Doctor> _baseRepository;

//        public DoctorServices(IMapper mapper, MyContext db, IBaseRepository<Doctor> baseRepository)
//        {
//            this._baseRepository = baseRepository;
//            base.BaseDal = baseRepository;
//        }
//        ///// <summary>
//        ///// 查询显示分页
//        ///// </summary>
//        ///// <param name="doctorName"></param>
//        ///// <param name="hospital"></param>
//        ///// <param name="ageLimit"></param>
//        ///// <param name="pageIndex"></param>
//        ///// <param name="pageSize"></param>
//        ///// <returns></returns>
//        //public async PageModel<Doctor,bool> GetDoctorList(string doctorName, string hospital, int ageLimit=0, int pageIndex = 1, int pageSize = 3)
//        //{
//        //    //var doctors = new List<Doctor>();
//        //    Expression<Func<Doctor, bool>> whereExpression = Doctor => Doctor.DoctorName.Contains(doctorName);
//        //    var doctors = _baseRepository.QueryPage(whereExpression, pageIndex, pageSize);
//        //    //doctors = (List<Doctor>)doctors.Where(x => string.IsNullOrEmpty(doctorName) || x.DoctorName.Contains(doctorName));
//        //    //doctors = (List<Doctor>)doctors.Where(x => string.IsNullOrEmpty(hospital) || x.DoctorName.Contains(hospital));
//        //    //doctors = (List<Doctor>)doctors.Where(x => x.AgeLimit == ageLimit);
//        //    //int count = doctors.Count();
//        //    //var query = doctors.OrderBy(x => x.Id).Skip((pageIndex - 1) * pageSize).Take(pageIndex).ToList();
//        //    //return (count, doctors);
//        //    return;
//        //}

//    }
//}
